<?
//引入所有子系统信息
include_once("../../../common/script/extender_import.php");



//根据接收过来的数据，对比日期和产品的变化。





//处理数据并且update
//获取数据
$_REQUEST['ai_student_info']=$_REQUEST['ai_student_school']." ".$_REQUEST['ai_student_grade']." ".$_REQUEST['ai_student_class'];
$sql=update_date($table_prefix."order_info",$_REQUEST,"order_id",$_REQUEST['order_id']);
$query = do_query($sql) or die ("error:".mysqli_error());

if($query)
{
    //去修改
    $_update_sql = "UPDATE `" . $table_prefix . "order_detail` 
                SET `school`='" . $_REQUEST['ai_student_school'] . "',
                    `grade`='" . $_REQUEST['ai_student_grade'] . "',
                    `class_`='" . $_REQUEST['ai_student_class'] . "',
                    `name`='" . $_REQUEST['ai_student_name'] . "'
                WHERE `order_nid`='" . $_REQUEST['order_id'] . "'";
    $query = do_query($_update_sql) or die ("error:".mysqli_error());


    if($query)
    {
        ?>
<script>
    alert('修改成功！');
    //父窗口刷新
    parent.layer.closeAll();
    parent.location.reload();
</script>
<?php
    }
}
else
{?>
<script>

    alert('修改失败！');
    //刷新页面
    parent.layer.closeAll();
    parent.location.reload();

</script>
<?php;}

exit;
?>

